<?php


 /**
  * 商品竞拍历史出价  
  * auction.js  up_history
  * Enter description here ...
  * @var unknown_type
  */

define('ROOT_PATH', str_replace("\\", '/', dirname(__FILE__)));
$config = include(ROOT_PATH.'/Lib/common.ini.php');

	$data = Init_GP(array('id'));   //竞拍商品Id
	$id = (int)$data['id'];
	$logdata = $get->getLogData($id);   //查看商品最近10条竞拍历史
	
	unset($data);
	foreach ($logdata as $value){
   		$data[] = array(
   			'mid'=>$value['uid'],
   			'tid'=>$value['aid'],
   			'bidtime'=>date('Y-m-d H:i:s',$value['addtime']),
   			'price'=>$value['bidprice'],
   			'ip'=>formatip($value['ip']),
   			'locate'=>$value['address'],
   			'nickname'=>$value['name']
   		);
    }
    
    $json['all'] = $data;
    echo json_encode($json);

?>